//
//  ILGMRCSharedInstance.m
//  ILGDemo
//
//  Created by happy on 2020/4/14.
//  Copyright © 2020 Happy. All rights reserved.
//

#import "ILGMRCSharedInstance.h"

@interface ILGMRCSharedInstance () <NSMutableCopying>

@end

@implementation ILGMRCSharedInstance

- (void)performTestMethod
{
    NSLog(@"%s", __func__);
}

static ILGMRCSharedInstance *_instance = nil;
+ (instancetype)sharedInstance
{
    static dispatch_once_t onceToken;
    dispatch_once(&onceToken, ^{
        _instance = [[super allocWithZone:NULL] init];
    });
    
    return _instance;
}

+ (instancetype)allocWithZone:(struct _NSZone *)zone {
    return [self sharedInstance];
}

- (id)copyWithZone:(NSZone *)zone {
    return self;
}

- (id)mutableCopyWithZone:(NSZone *)zone {
    return self;
}

- (instancetype)retain {
    return self;
}

- (NSUInteger)retainCount {
    return NSUIntegerMax;
}

- (oneway void)release {

}

- (instancetype)autorelease {
    return self;
}

@end
